package com.harry.hr.biz.impl;

import java.util.List;
import org.hibernate.criterion.MatchMode;
import org.hibernate.criterion.Order;
import com.harry.hr.biz.ConfigFileBIZ;
import com.harry.hr.dao.ConfigFileDAO;
import com.harry.hr.entity.ConfigFileFirstKind;
import com.harry.hr.entity.ConfigFileSecondKind;
import com.harry.hr.entity.ConfigFileThirdKind;
import com.harry.hr.entity.ConfigMajor;
import com.harry.hr.entity.ConfigMajorKind;
import com.harry.hr.entity.ConfigPrimaryKey;
import com.harry.hr.entity.ConfigPublicChar;
import com.harry.hr.entity.ConfigQuestionFirstKind;
import com.harry.hr.entity.ConfigQuestionSecondKind;
import com.harry.hr.entity.SalaryStandard;


public class ConfigFileBIZImpl implements ConfigFileBIZ {
	private ConfigFileDAO configFileDAO;

	public void setConfigFileDAO(ConfigFileDAO configFileDAO) {
		this.configFileDAO = configFileDAO;
	}

	public List<ConfigFileFirstKind> getConfigFileFirstKindList() {
		return this.configFileDAO.getConfigFileFirstKindList();
	}

	public List<ConfigFileSecondKind> getConfigFileSecondKindList(String firstKindId) {
		return this.configFileDAO.getConfigFileSecondKindList(firstKindId);
	}

	public List<ConfigFileThirdKind> getConfigFileThirdKindList(String secondKindId) {
		return this.configFileDAO.getConfigFileThirdKindList(secondKindId);
	}

	public List<ConfigMajor> getConfigMajorList(String majorKindId) {
		return this.configFileDAO.getConfigMajorList(majorKindId);
	}

	public List<ConfigMajorKind> getConfigMajorKindList() {
		return this.configFileDAO.getConfigMajorKindList();
	}

	public List<ConfigPrimaryKey> getConfigPrimaryKeyList() {
		return this.configFileDAO.getConfigPrimaryKeyList();
	}

	public List<ConfigPublicChar> getConfigPublicCharList(String attributeKind) {
		return this.configFileDAO.getConfigPublicCharList(new ConfigPublicChar(attributeKind),MatchMode.EXACT,Order.asc("pbcId"));
	}

	public List<ConfigQuestionFirstKind> getConfigQuestionFirstKindList() {
		return this.configFileDAO.getConfigQuestionFirstKindList();
	}

	public List<ConfigQuestionSecondKind> getConfigQuestionSecondKindList() {
		return this.configFileDAO.getConfigQuestionSecondKindList();
	}
	
	public List<SalaryStandard> getSalaryStandardList() {
		return this.configFileDAO.getSalaryStandardList();
	}

	public List<ConfigPublicChar> getEngageTypes() {
		return getConfigPublicCharList("招聘类型");
	}
}
